#ifndef _HMIADAPTER_MODEL_LOGIC_TURNLAMPMODEL_H_
#define _HMIADAPTER_MODEL_LOGIC_TURNLAMPMODEL_H_

#ifdef __cplusplus
extern "C" {
#endif

#include "Common/HmiAdapterBase.h"

typedef struct TurnLampModel
{
    ImeterModel model_;
} TurnLampModel;

typedef enum
{
    State_Off = 0x00,        //00
    State_LeftOn  = 0x01,    //01
    State_RightOn = 0x02,    //10
    State_BothOn  = 0x03     //11
} TurnLampState;

typedef enum {
    Blink_Off = 0x00,
    Blink_On = 0x01
} TurnLampBlink;

typedef enum {
    EV_BothOff = 0x00,
    EV_LeftOn,
    EV_RightOn,
    EV_BothOn,
    EV_Unknown
} TurnLampEvent;

typedef struct LampWorkingData
{
    TurnLampEvent event;
    TurnLampBlink leftBlinkState;
    TurnLampBlink rightBlinkState;
    uint32_t blinkCountDown;
    TurnLampState currentState;
    bool hasleftTurnWidget;
    bool hasRightTurnWidget;
} LampWorkingData;

extern LampWorkingData WorkingData;

extern TurnLampModel g_turnLampModelInstance;

#ifdef __cplusplus
}
#endif

#endif

